import { defineConfig } from "vite";
import vue from "@vitejs/plugin-vue";
import Components from "unplugin-vue-components/vite";
import { AntDesignVueResolver } from "unplugin-vue-components/resolvers";
export default defineConfig({
  resolve: { alias: { "@": "/src" } },
  plugins: [
    vue(),
    Components({ resolvers: [AntDesignVueResolver({ importStyle: false })] }),
  ],
  css: {
    preprocessorOptions: {
      scss: {
        javascriptEnabled: true,
        additionalData: `@import "src/assets/common.scss";`,
      },
    },
  },
  server: {
    host: true,
    port: 3000,
    open: true,
    cors: true
  }
});
